"""
标记、线条样式和颜色
fmt = '[marker][line][color]'
"""

import matplotlib.pyplot as plt

x = [0, 1, 2, 3, 4, 5]
y = [2, 10, 0, 8, 3,5]

rows = 2
cols = 2
fig, axs = plt.subplots(rows, cols, figsize=(10, 10))

axs[0,0].plot(x, y, marker='.')
axs[0,0].grid()

axs[0,1].plot(x, y, marker='.')
axs[0,1].grid(color='g', linestyle=':')

axs[1,0].plot(x, y, marker='o')
axs[1,0].grid(color='r', linestyle='--', axis='x')  # 显示x轴网格

axs[1,1].plot(x, y, marker='o')
axs[1,1].grid(color='b', linestyle='-.', axis='y')  # 显示y轴网格

plt.show()

